import { get, post } from "./http"

//--菜单模块start------------
// 添加
export const reqmenuadd = params => post("/api/menuadd", params);

//列表
export const reqmenulist = params => get("/api/menulist", params)

//删除
export const reqmenudelete = params => post("/api/menudelete", params)

//详情
export const reqmenuinfo = params => get("/api/menuinfo", params)

//修改
export const reqmenuedit = params => post("/api/menuedit", params)
//--菜单模块end------------
//--角色模块start------------
// 添加
export const reqroleadd = params => post("/api/roleadd", params);

//列表
export const reqrolelist = () => get("/api/rolelist")

//删除
export const reqroledelete = params => post("/api/roledelete", params)

//详情
export const reqroleinfo = params => get("/api/roleinfo", params)

//修改
export const reqroleedit = params => post("/api/roleedit", params)
//--角色模块end------------
//--管理员模块start------------
// 添加
export const requseradd = params => post("/api/useradd", params);

//列表
export const requserlist = params => get("/api/userlist",params)

//删除
export const requserdelete = params => post("/api/userdelete", params)

//详情
export const requserinfo = params => get("/api/userinfo", params)

//修改
export const requseredit = params => post("/api/useredit", params)

//分页
export const requsercount = params => get("/api/usercount", params)

//登录
export const reqLogin =(params)=>post("/api/userlogin",params)
//--管理员模块end------------
//--分类模块start------------
// 添加
export const reqcateadd = params => post("/api/cateadd", params,true);

//列表
export const reqcatelist = params => get("/api/catelist",params)

//删除
export const reqcatedelete = params => post("/api/catedelete", params)

//详情
export const reqcateinfo = params => get("/api/cateinfo", params)

//修改
export const reqcateedit = params => post("/api/cateedit", params,true)
//--分类模块end------------
//--规格模块start------------
// 添加
export const reqspecsadd = params => post("/api/specsadd", params);

//列表
export const reqspecslist = params => get("/api/specslist",params)

//删除
export const reqspecsdelete = params => post("/api/specsdelete", params)

//详情
export const reqspecsinfo = params => get("/api/specsinfo", params)

//修改
export const reqspecsedit = params => post("/api/specsedit", params)

//总数
export const reqspecscount=()=>get("/api/specscount")
//--规格模块end------------
//--商品模块start------------
// 添加
export const reqgoodsadd = params => post("/api/goodsadd", params,true);

//列表
export const reqgoodslist = params => get("/api/goodslist",params)

//删除
export const reqgoodsdelete = params => post("/api/goodsdelete", params)

//详情
export const reqgoodsinfo = params => get("/api/goodsinfo", params)

//修改
export const reqgoodsedit = params => post("/api/goodsedit", params,true)

//总数
export const reqgoodscount=()=>get("/api/goodscount")
//--商品模块end------------
//--会员管理模块start------------
// 添加

//列表
export const reqmemberlist =()=> get("/api/memberlist")

//详情
export const reqmemberinfo = params => get("/api/memberinfo", params)

//修改
export const reqmemberedit = params => post("/api/memberedit", params)

//--会员管理模块end------------

//--轮播图模块start------------
// 添加
export const reqbanneradd = params => post("/api/banneradd", params,true);

//列表
export const reqbannerlist = params => get("/api/bannerlist",params)

//删除
export const reqbannerdelete = params => post("/api/bannerdelete", params)

//详情
export const reqbannerinfo = params => get("/api/bannerinfo", params)

//修改
export const reqbanneredit = params => post("/api/banneredit", params,true)

//--轮播图模块end------------
//--轮播图模块start------------
// 添加
export const reqseckadd = params => post("/api/seckadd", params);

//列表
export const reqsecklist = () => get("/api/secklist")

//删除
export const reqseckdelete = params => post("/api/seckdelete", params)

//详情
export const reqseckinfo = params => get("/api/seckinfo", params)

//修改
export const reqseckedit = params => post("/api/seckedit", params)

//--轮播图模块end------------